# Maintainer: John Nunley <dev@notgull.net>
pkgname=parse-changelog
pkgver=0.6.8
pkgrel=0
pkgdesc="simple changelog parser"
url="https://github.com/taiki-e/parse-changelog"
arch="all"
license="Apache-2.0 OR MIT"
makedepends="
	cargo
	cargo-auditable
	rust
	"
source="$pkgname-$pkgver.tar.gz::https://github.com/taiki-e/parse-changelog/archive/refs/tags/v$pkgver.tar.gz
	Cargo.lock
	"

prepare() {
	default_prepare
	cp "$srcdir/Cargo.lock" "$builddir"
	cargo fetch --target="$CTARGET" --locked
}

build() {
	cargo auditable build --release --frozen
}

check() {
	cargo test --workspace --release --frozen
}

package() {
	install -Dm755 target/release/parse-changelog "$pkgdir"/usr/bin/parse-changelog
}

sha512sums="
038054f6dd819e81ee8ef15a2206fab36a2ae6b905e7dfbe0683f880fae4a1690500db5a40b5ead26daf98e76ab913c3a15ccfc9f8bf4e5b1e4d4a35768b5235  parse-changelog-0.6.8.tar.gz
78532e9cda6ba9bd14131eac10b054ff86205e8d4e3fda3804ef5378685e95d0583451b88ff92065fa07a060f1138eedd94073ac026731f8c06a8e1f9bb2ec21  Cargo.lock
"
